An Application to Lac Ste Anne County, Alberta
# Load packages
library(tmaptools)
library(tmap)
library(sf)
library(tidyverse)
library(leaflet)
library(htmlwidgets)
library(leaflet.extras)
library(Hmisc)
knitr::opts_chunk$set(fig.width = 12, fig.height = 10)As part of the Ecosystem Services Assessment (ESA), the Alberta Biodiversity Monitoring Institute has developed a Clean Water Prioritization Tool (CWPT) to help guide municipalities in maintaining and enhancing water-related ecosystem services throughout their jurisdiction. Improvement of water quality is an important goal among many municipalities, and practical guidance on where to target conservation and management efforts to achieve ecosystem service gains in an efficient manner is needed.
The CWPT is a mapping product designed to give landowners, decision-makers, and extension agents information on the relative importance of each quarter-section in contributing to the provision of clean surface water, as well as guidance on appropriate management actions.
The CWPT is based off a methodology developed by the Natural Capital Project (2018) and is a spatially-explicit tool designed to identify areas of strategic importance for improving and maintaining water quality. In particular, the CWPT is designed around the objective of reducing nutrient runoff, which can improve downstream water quality and biodiversity, as well as potentially decrease water treatment costs and nutrient-related health risks to humans and livestock.
The non-point source runoff of nutrients across the landscape is estimated using export coefficients developed for major landcover and human footprint types, in conjunction with annual precipitation and simulation of overland flow based on a hydrologically corrected digital elevation model (Habib et al 2016). Specifically, the CWPT relies on three modelled attributes of the landscape to evaluate the relative importance of each quarter-section:
Upslope Accumulation: The sum total of nutrients exported from upslope areas whose flow paths move through the quarter-section.
Downslope Retention: The sum total of nutrient retention potential of all downslope areas along the flow path from the quarter-section to a river or stream.
On-pixel Contribution: The nutrient source and retention capabilities of each quarter-section.
# Import data
ab_cwpt_indices <- st_read("./SpatialData/Clean/ab_cwpt_indices.shp", stringsAsFactors = FALSE, quiet = TRUE) # Quarter-section level data
ab_counties <- st_read("./SpatialData/Clean/ab_counties.shp", stringsAsFactors = FALSE, quiet = TRUE) # Counties shape file
# Filter for Lac Ste Anne County
lsac_cwpt <- ab_cwpt_indices %>%
filter(C_MD_SA == "Lac Ste. Anne County")
lsac <- ab_counties %>%
filter(C_MD_SA == "Lac Ste. Anne County")
# Set projection
lsac_cwpt <- st_transform(lsac_cwpt, "+init=epsg:4326")
lsac <- st_transform(lsac, "+init=epsg:4326")
names(st_geometry(lsac)) = NULL
names(st_geometry(lsac_cwpt)) = NULLThe relative importance of each quarter-section to service delivery depends on the first two attributes, both of which are highly related to landscape position and nearby land use. Quarters that are topographically situated such that they receive large amounts of nutrient runoff from upslope areas will have a greater opportunity to trap nutrients. Note that this can be due to either draining a large area, or draining an area with high runoff, e.g. due to intensive development (or both).
Importance is also reflected by the second attribute, downslope retention potential. This attribute refers to the length of the flow path downslope of the quarter before flowing into a stream or river, weighted by the ability of land along that path to filter and trap nutrients. If downslope nutrient retention potential is low (due to a short flow path and/or highly developed land along it), management actions on the quarter will be relatively more beneficial for water quality services. Conversely, if retention potential downslope is high, the area will be less important.
For both of these continuous variables, each quarter-section is binned into one of ten equal-sized groups and assigned a score between 1 and 10. An overall landscape importance score is calculated as the average between the two intermediate scores. Note that for the purposes of averaging these two attributes, the binned scores for downslope retention are reversed, such that a higher score represents higher importance (i.e. lower retention potential).
The map below shows the landscape importance score associated with each quarter-section located within Lac Ste Anne County, Alberta. The user can select specific quarter-sections and be given the legal land description and importance score, as well as display satellite imagery.
# Prepare layers and colors
# Define colours
land <- colorNumeric("Blues", domain = lsac_cwpt$land_mp) # For landscape importance index score
c1 <- (c("#00441b","#238b45", "#74c476","#a1d99b", "#e5f5e0",
"#f6e8c3","#dfc27d", "#bf812d","#8c510a", "#543005")) # For on-pixel index score
c2 <- colorRampPalette(c1) # Interpolate
lsac_cwpt$colour <- c2(10)[lsac_cwpt$self_bn]
cp <- colorNumeric(c("#00441b","#238b45", "#74c476","#a1d99b", "#e5f5e0",
"#f6e8c3","#dfc27d", "#bf812d","#8c510a", "#543005"),
domain = lsac_cwpt$self_bn)
# Create df's of filtered landscape importance index score ranges
lsac_cwpt_5 <- lsac_cwpt %>%
filter(land_mp >= 5)
lsac_cwpt_7 <- lsac_cwpt %>%
filter(land_mp >= 7)
lsac_cwpt_9 <- lsac_cwpt %>%
filter(land_mp >= 9)
# Generate leaflet map of landscape position importance
lsac_map_land <-
lsac %>%
leaflet() %>%
addTiles() %>%
addProviderTiles("Esri.WorldImagery", group = "Imagery") %>%
addFullscreenControl() %>%
addResetMapButton() %>%
# Polygon Layers
addPolygons(color = "#282828", weight = 2, smoothFactor = 0.2, opacity = 2) %>%
addPolygons(data = lsac_cwpt, color = "#444444", weight = 0.4, smoothFactor = 0.5,
opacity = 1.0, fillOpacity = 0.6,
fillColor = ~ land(land_mp), group = "Landscape Position Importance Score",
popup = paste("Legal Land Description:", lsac_cwpt$LLD, "<br>",
"Landscape Position Importance Score:", lsac_cwpt$land_mp)) %>%
# Legend Layer
addLegend(data = lsac_cwpt, position = "bottomright", pal = land, values = ~ land_mp,
title = "Index Score", opacity = 1,
group = "Landscape Position Importance Score") %>%
# Want to add a way to search for an LLD. Probably best to do so via shiny?
# Enter into different fields the range, section, QS, meridian, etc.
# Search Features Layer
# addSearchFeatures(targetGroups = "Landscape Position Importance Score",
# options = searchFeaturesOptions(zoom = 10, openPopup = TRUE)) %>%
# Layers Control
addLayersControl(overlayGroups = c("Landscape Position Importance Score",
"Imagery"),
options = layersControlOptions(collapsed = FALSE)) %>%
hideGroup("Imagery")
lsac_map_landThe last step of the CWPT involves the third landscape attribute, on-pixel contribution. Using export coefficients from ABMI’s water purification model (Habib et al 2016), the nutrient load generated from each quarter-section is calculated. Similar to the other two attributes, this continuous variable is mapped into ten equal-sized bins and each quarter-section is given a score.
This second score provides an indication as to what type of management actions may be appropriate. For example, a quarter-section with a low on-pixel contribution score will be generating a relatively small amount of nutrient runoff. In this case, the combination of low on-pixel sources and a high nutrient retention rate suggest that management oriented around conservation of existing landcover is most suitable. On the other hand, a high score would indicate that a high degree of nutrient runoff is occurring (due to high on-pixel sources and/or low rentention rates) and that restoration and/or mitigation actions should be prioritized. Such activities, for example, may include planting native vegetation or permanent cover, revegetating riparian areas, livestock management, and fertilizer management.
The two scores can be used in combination to identify priority quarter-sections within a region and plan appropriate management actions. The map below displays the on-pixel contribution index score associated with each quarter-section in Lac Ste Anne County; however, the user can filter the data to view only those quarter-sections that score progressively higher on the landscape importance score (based on upslope accumulation and downslope retention). A decision-maker can, for instance, choose to select only those quarters that score above a certain threshold on the importance index, and then use the second score as an indicator of which suite of management actions would be suitable at each site.
# Generate leaflet map of on-pixel scores
lsac_map_pix <-
lsac %>%
leaflet() %>%
addTiles() %>%
addProviderTiles("Esri.WorldImagery", group = "Imagery") %>%
addFullscreenControl() %>%
addResetMapButton() %>%
# Polygon Layers
addPolylines(color = "#282828", weight = 2, smoothFactor = 0.2) %>%
addPolygons(color = "#282828", weight = 2, smoothFactor = 0.2,
opacity = 2, group = "None") %>%
addPolygons(data = lsac_cwpt, color = "#444444", weight = 0.4, smoothFactor = 0.5,
opacity = 1.0, fillOpacity = 0.6,
fillColor = ~ colour, group = "On-Pixel Contribution (All)",
popup = paste("Legal Land Description:", lsac_cwpt$LLD, "<br>",
"Score:", lsac_cwpt$self_bn)) %>%
addPolygons(data = lsac_cwpt_5, color = "#444444", weight = 0.4, smoothFactor = 0.5,
opacity = 1.0, fillOpacity = 0.6,
fillColor = ~ colour, group = "On-Pixel Contribution (Landscape >= 5)",
popup = paste("Legal Land Description:", lsac_cwpt_5$LLD, "<br>",
"Score:", lsac_cwpt_5$self_bn)) %>%
addPolygons(data = lsac_cwpt_7, color = "#444444", weight = 0.4, smoothFactor = 0.5,
opacity = 1.0, fillOpacity = 0.6,
fillColor = ~ colour, group = "On-Pixel Contribution (Landscape >= 7)",
popup = paste("Legal Land Description:", lsac_cwpt_7$LLD, "<br>",
"Score:", lsac_cwpt_7$self_bn)) %>%
addPolygons(data = lsac_cwpt_9, color = "#444444", weight = 0.4, smoothFactor = 0.5,
opacity = 1.0, fillOpacity = 0.6,
fillColor = ~ colour, group = "On-Pixel Contribution (Landscape >= 9)",
popup = paste("Legal Land Description:", lsac_cwpt_9$LLD, "<br>",
"Score:", lsac_cwpt_9$self_bn)) %>%
# Legend Layers
addLegend(data = lsac_cwpt, position = "bottomright", pal = cp, values = ~ self_bn,
title = "On-Pixel Contribution Score", opacity = 1) %>%
# Layers Control
addLayersControl(overlayGroups = "Imagery",
baseGroups = c("None",
"On-Pixel Contribution (All)",
"On-Pixel Contribution (Landscape >= 5)",
"On-Pixel Contribution (Landscape >= 7)",
"On-Pixel Contribution (Landscape >= 9)"),
options = layersControlOptions(collapsed = FALSE)) %>%
hideGroup(c("On-Pixel Contribution (All)",
"On-Pixel Contribution (Landscape >= 5)",
"On-Pixel Contribution (Landscape >= 7)",
"On-Pixel Contribution (Landscape >= 9)",
"Imagery"))
lsac_map_pixThe CWPT can be used to identify priority areas and guide the placement of conservation and restoration projects on the landscape. The first index score, landscape importance, indicates the relative importance of each quarter-section within a region, whereas the second score, on-pixel contribution, can be used as a guide for deciding upon the appropriate course of action.
It is important to keep in mind that local conditions will vary widely at each site, and that some management actions may be more suitable / effective than others. Using this tool as a first-step screening process, landowners, decision-makers, and extension officials can work together to determine a mutually beneficial course of action to improve or mantain water-related ecosystem services.